import React from "react";
import {Button, Flex, Space} from "antd";
import {ArrowLeftOutlined} from "@ant-design/icons";

export function ChatInfoPanel({situation, onClose, onSummarize, view, onSetView}) {
  return (
    <Flex justify="space-between" align="center" style={{width: '100%', padding: "10px"}}>
      <Space>
        <Button icon={<ArrowLeftOutlined/>} onClick={onClose}>
          返回
        </Button>
        <div>场景: {situation}</div>
        <div>你：{}</div>
      </Space>
      <Space>
        <Button onClick={onSetView}>
          {view === "chat" ? "切换至对话" : "切换至语音"}
        </Button>
        <Button type="primary" onClick={onSummarize}>
          结束对话，获取总结
        </Button>
      </Space>
    </Flex>
  );
}

export default ChatInfoPanel;